/*
 *  DbTableEntry.h
 *  StrategyInspector
 *
 *  Created by jiro on 12/08/07.
 *  Copyright 2012 jiro music. All rights reserved.
 *
 */

#pragma once

#include <vector>
#include "Nodes.h"

class DbTableEntry
{
public:

	static NSString* tableName();
	static NSString* queryCreateTable();
	static NSString* queryFieldsOfCreateTable();
	static NSString* queryInsertInitialValues();
	static NSString* querySelectAll();
	static NSString* querySelectAll( const std::vector< ClauseNode >& clauses );
	static NSString* querySelectAll( NSString* tableName, const std::vector< ClauseNode >& clauses );
	static NSString* querySelect( const std::vector< FieldNode >& fieldNodes, const std::vector< ClauseNode >& clauses );
	static NSString* querySelect( const std::vector< FieldNode >& fieldNodes, NSString* tableName, const std::vector< ClauseNode >& clauses );

	virtual NSString* queryInsert() const = 0;
	virtual NSString* queryInsertValue() const = 0;
	virtual NSString* queryInsertWithSerialValue() const;
	virtual NSString* queryInsertValueWithSerialValue() const;

};
